<%-- 
    Document   : deliver
    Created on : May 6, 2013, 12:19:40 AM
    Author     : Vitalii D.
--%>
<%@page import="com.charlie.beans.SoProduct"%>
<%@page import="com.charlie.beans.ShipmentOrder"%>

<%@include file="/header.jsp" %>

<div class="left_side">
    <jsp:include page="/blocks/conditionalLeftBar.jsp" />
</div>

<div class="right_side">
    <h2 class="content_title" style="font-family: Tahoma; font-size: 20pt">View order #</h2>
    <div class="white_block" overflow="scroll"> 
        <h2 style="font-family: Arial; font-size: 18pt;color: #404040; text-align: center; font-weight: 400">Deliver the order</h2>
        <table>
            <tr class="cart_items_header">
                <td colspan="2">
                    Selected guitars:
                    <ul>
                        <%
                        ShipmentOrder order = (ShipmentOrder) request.getAttribute("order");
                        for (SoProduct product : order.getSoProductCollection()) { %>
                        <li><%= product.getProductId().getName() %> (<%= product.getProductId().getCost() %>$ x <%= product.getAmount() %>)</li>
                        <% }%>
                    </ul>
                </td>
            </tr>
            <tr>
                <td><br>Selected warehouse:</td>
                <td><br>${order.getWarehouseId().getLocation()}</td>
            </tr>
            <tr>
                <td>Delivery location:</TD>
                <td>${order.getLocation()}</td>
            </tr>
            <tr>
                <td><br>Price: ${order.getShipingCost()} + ${order.getCost()} = ${order.getShipingCost() + order.getCost()}$</td>
            </tr>
            <tr>
                <td>Comment:
                    <form action="" method="post">
                    <p>Comment:</p>
                    <p><textarea rows="10" cols="45" name="text"></textarea></p>
                    <p><input type="submit" value="Deliver"></p>
                    </form>
                </td>
            </tr>
        </table>
    </div>
</div>
    
<%@include file="/footer.jsp" %>